
public class Time{
	int hour, minute;
	public Time(int theHour, int theMinute){
		hour = theHour;
		minute = theMinute;
	}
	public int getHour(){
		return hour;
	}
	public int getMinute(){
		return minute;
	}
	public int compareTo(Time o) {
		if (o.getHour() < hour){
			return 1;
		}
		else if (o.getHour() > hour){
			return -1;
		}
		else{
			if (o.getMinute() < minute){
				return 1;
			}
			else if (o.getMinute() > minute){
				return -1;
			}
			else{
				return 0;
			}
		}
	}
}
